package com.mac.pojo;

import java.sql.Date;

/**
 * 创建留言表 Messages 实体类
 * 包含用户留言信息
 */
public class Messages {
    // 留言ID
    private Integer messageId;

    // 用户ID
    private Integer userId;

    // 文章内容
    private String content;

    // 留言日期
    private Date createdAt;

    public Messages() {
    }

    public Messages(Integer messageId, Integer userId, String content,  Date createdAt) {
        this.messageId = messageId;
        this.userId = userId;
        this.content = content;
        this.createdAt = createdAt;
    }

    public Integer getMessageId() {
        return messageId;
    }

    public void setMessageId(Integer messageId) {
        this.messageId = messageId;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public  Date getCreatedAt() {
        return createdAt;
    }

    public void setCreatedAt(Date createdAt) {
        this.createdAt = createdAt;
    }

    @Override
    public String toString() {
        return "message{" +
                "messageId=" + messageId +
                ", userId=" + userId +
                ", content='" + content + '\'' +
                ", createdAt=" + createdAt +
                '}';
    }
}
